FROM tomcat:9.0.12-jre8-alpine

RUN apk add vim
RUN apk add --update ttf-dejavu fontconfig && rm -rf /var/cache/apk/*

RUN echo "set mouse=" >> /root/.vimrc

ENV CLUSTER_MODE=API_SERVER
ENV jdbc.url="jdbc:mysql://rm-wz9r6iduf2adc753l90110.mysql.rds.aliyuncs.com:3306/yhb?useUnicode=true&characterEncoding=utf8&allowMultiQueries=true&serverTimezone=Hongkong"
ENV redis.host="r-wz9fkuifwgrltwl1gp.redis.rds.aliyuncs.com"
ENV redis.pass="r-wz9fkuifwgrltwl1gp:Yhb2019#"

ENV aliyun.mq.mode="prod"
ENV aliyun.mq.gid="GID_MAIN"
ENV aliyun.mq.accessPoint="http://MQ_INST_1825751410379534_BbeEsIF8.cn-shenzhen.mq-internal.aliyuncs.com:8080"
ENV aliyun.mq.topic="pos"
ENV aliyun.mq.tag="prod"

ENV config.isDebug="false"
ENV config.url="https://api.ylmvip.cn/"

ENV alipay.appid="2019031563530847"
ENV alipay.privateKey="MIIEowIBAAKCAQEAt9K/3kaXf1l3mCgYoeHarhvxm34yd11w3xfz45IvDuGbvhB6GbBlsq8s5nc05Zcqbx/U+PqJK/y2zx5uUGDc1Xr00Afvxh/bqrTnRrWr4U84jGaA0lXLXZWBbf+/LhYaBjQLC+z3tQHQk/mU7HrlvfYs3u1PeEwjnM8krZhCsV+SKc31Tt39X2t9S9tlmSq8XHFu0H9HleEmfPyEd3hcaSz4XQl/BVCLI9WKkHiToY2kQ9EJgf6EFziCWDr7tT40KmPPP6P7en5DuzH0bMuBDRA/DhI80ENxDdk/idnuyKhOkpgSOwa19o18Zt2sPjDdXB3f8O/BDvsply+wfNdSAwIDAQABAoIBADzxCpkHMCyRHZv9FwV8GgKE0xmowdRezw+3Iiz9BsrZMsfVMJWZrG2Ls8gIFypSbkf+9p1Aef9yPaz2ur29DxlbNRROvUgiwbGbXd1MV1pP6EBrryOMO+qfqRQtqFUAEMqjsFHY0tpYaqzUHnIz4DyVA5U4eZM5MslGxzMh+m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G9w0BAQEFAAOCAQ8AMIIBCgKCAQEApF85Od3EJLFPyVML8kZ4cnA2nKO1Yi9AEOzmVSe1kLOKc2UcgxOnRz2vW3mB56Za7hh/yq4L6TNXYdWf3zJ7cjzn6jTpc6wKibCKpf+t12IaAUQSok9qxcqP7dymFYngYCtj32dFa4oZEO2d1jEfLucIonVgRo8fxnDpVhuf3GMVENiEhrsl6m0rWor2+sROLPiFrpIh9YbIkCFvEpf2qR0wAT9uFNSIMIt6mvPwEFBtpCFTnmWCz2LN6xMkypuS6O5YpezIgQs7+8tgdBY1k1VEc4yYySwpCMCW5DFQ1wssspUdC3iE6gbVzA4tZHWI9DNa9v0ufhODe5rYV+WhgwIDAQAB"

ENV umeng.push.android.ak="5c7c9f5d3fc19521cd000a67"
ENV umeng.push.android.as="vmxk8zx12hs0rdqlpue89jpp56lrfoym"

ENV umeng.push.iOS.ak="5c78b3a361f5643e9c00045a"
ENV umeng.push.iOS.as="tmck3fxakidto3ctp5th5k75snqrevlb"

#ENV yinsheng.unionpay.baseUrl="https://ft.ysepay.com/gate"
#ENV yinsheng.unionpay.accessCode="801421099990850"
#ENV yinsheng.unionpay.appKey="1061330e70c84e08a0e5c006244c50d6"

ENV yinsheng.unionpay.baseUrl="https://fintech.ysepay.com/gate"
ENV yinsheng.unionpay.accessCode="801584066669214"
ENV yinsheng.unionpay.appKey="8baf6af6796f49a4adb2786cd8573723"

ENV rpc.cpsIp="http://47.106.28.85"
ENV rpc.aesKey="Y2hlbmppYWhhbmRzb21lIQ=="
ENV rpc.aesIv="chenjiahandsome!"
ENV rpc.aesAlgorithm="AES/CBC/PKCS5Padding"

ENV CPS_AVAILABLE="false"


COPY deploy/taillog /usr/bin/
COPY deploy/trace /usr/bin/

RUN rm -rf /usr/local/tomcat/webapps && mkdir -p /usr/local/tomcat/webapps && chmod +x /usr/bin/taillog && chmod +x /usr/bin/trace

COPY deploy/Shanghai /etc/timezone
COPY deploy/Shanghai /etc/localtime

COPY deploy/setenv.sh /usr/local/tomcat/bin/

COPY deploy/runtime_dependencies /data/

COPY target/ROOT.war /usr/local/tomcat/webapps/


WORKDIR /usr/local/tomcat/logs
EXPOSE 8080
EXPOSE 60222